<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2018/1/30
 * Time: 11:14
 */
namespace app\api\validate;

use think\Validate;

class Common extends Validate
{
    protected $rule = [
        'phone' => ['require','regex' => '/^1[3|4|5|7|8][0-9]\d{8}$/i'],
    ];
    protected $message = [
        'phone.regex' => 400003,
        'phone.unique' => 400004,
        'phone.require' => 400001,
    ];
    protected $scene = [
        'check_phone' => ['phone'],
    ];
}